﻿@{
    ViewBag.Title = "Manage";
    Layout = "~/Views/Shared/_Layout.cshtml";
}

@section header{
    <script type="text/javascript" src="~/DatePicker/WdatePicker.js"></script>
    <script type="text/javascript">
        function manageConfirm(id) {
            var sort = $('#txtSort').val();
            var addTime = $('#txtAddTime').val();
            $.post('/Admin/Article/ManageConfirm/' + id, { 'Sort': sort, 'AddTime': addTime }, function (jsonData) {
                if (jsonData.Status == '1') {
                    window.top.window.$.messager.alert('OK', jsonData.Message);        //主窗口弹出消息提示
                    $.globalParas.updateDataGridInTab();                                              //清除选中，刷新表格
                    $.globalParas.closeComWindow();                                                    //关闭弹出窗口
                } else {
                    window.top.window.$.messager.alert('Error', jsonData.Message);      //主窗口弹出消息提示
                }
            }, 'json');
        }
    </script>
    <style type="text/css">
        #tblMgr {
            width: 300px;
            margin: 5px auto 0;
        }

            #tblMgr td input, textarea {
                width: 210px;
            }
    </style>
}
<div>
    <table id="tblMgr">
        <tr>
            <td>排序：</td>
            <td><input type="text" id="txtSort" value="@ViewBag.Sort" /></td>
        </tr>
        <tr>
            <td>发布时间：</td>
            <td><input id="txtAddTime" class="Wdate" type="text" onclick="WdatePicker();" value="@ViewBag.AddTime"></td>
        </tr>
        <tr>
            <td></td>
            <td><a class="easyui-linkbutton" data-options="iconCls:'icon-ok'" onclick="manageConfirm(@ViewBag.Id);">确定</a></td>
        </tr>
    </table>
</div>

